﻿using Net.Web.Framework.Mvc;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Web.Mvc;

namespace Net.Web.Models.Jobs
{
    /// <summary>
    /// 创建职位实体对象
    /// </summary>
    public class JobCreateModel : BaseModel
    {
        public JobCreateModel()
        {
            this.AvailableWorkType = new List<SelectListItem>();
            this.AvailableCategory = new List<SelectListItem>();
        }

        /// <summary>
        /// 职位名称
        /// </summary>
        [DisplayName("职位名称")]
        [AllowHtml]
        public string Name { get; set; }

        /// <summary>
        /// 工作类型
        /// </summary>
        public IList<SelectListItem> AvailableWorkType { get; set; }
        /// <summary>
        /// 工作方式
        /// </summary>
        [DisplayName("工作类型")]
        public int WorkTypeId { get; set; }

        /// <summary>
        /// 介绍
        /// </summary>
        [DisplayName("职位说明")]
        public string Memo { get; set; }

        [DisplayName("所属分类")]
        public int CategoryId { get; set; }

        /// <summary>
        /// 浏览次数
        /// </summary>
        public int Times { get { return 0; } }

        /// <summary>
        /// 是否删除
        /// </summary>
        public bool Deleted { get { return false; } }

        /// <summary>
        /// 是否启用该职位
        /// </summary>
        [DisplayName("是否启用")]
        public bool Active { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreateOn { get { return DateTime.Now; } }

        /// <summary>
        /// 
        /// </summary>
        public IList<SelectListItem> AvailableCategory { get; set; }
    }
}